Skip to content

feat(Settings): add secure environment editor in localhost:3001 #854

Merged
Lightheartdevs merged 2 commits intoLight-Heart-Labs:mainfrom
gabsprogrammer:settings-env-editor
Apr 8, 2026
Merged

feat(Settings): add secure environment editor in localhost:3001 #854
Lightheartdevs merged 2 commits intoLight-Heart-Labs:mainfrom
gabsprogrammer:settings-env-editor

Conversation

@gabsprogrammer
Copy link
Copy Markdown
Contributor

No description provided.

@gabsprogrammer gabsprogrammer changed the title feat:(Settings) env editor in localhost:3001 feat(Settings): add secure environment editor in localhost:3001 Apr 8, 2026
@gabsprogrammer
Copy link
Copy Markdown
Contributor Author

image

Copy link
Copy Markdown
Collaborator

@Lightheartdevs Lightheartdevs left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

APPROVE. Security model is solid: secrets never sent to browser, endpoints authenticated, raw mode rejected, unknown keys rejected, atomic writes with backup, 30 security tests. One defense-in-depth gap: no newline/null-byte rejection in submitted values (not exploitable in current architecture — Docker Compose and dotenv treat as literal strings). Will fix in a follow-up PR.

@Lightheartdevs Lightheartdevs merged commit 551598d into Light-Heart-Labs:main Apr 8, 2026
29 checks passed
Lightheartdevs added a commit that referenced this pull request Apr 8, 2026
Adds validation in _serialize_form_values to reject values containing
\n, \r, or \0. Prevents .env injection where a value like
"3010\nINJECTED_KEY=malicious" could write an extra line to .env.

Not exploitable in the current architecture (Docker Compose and Python
dotenv treat values as literal strings), but closes a defense-in-depth
gap identified during the #854 security audit.

Adds 2 tests: newline injection rejected (400), null byte rejected (400).

Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
Lightheartdevs added a commit that referenced this pull request Apr 8, 2026
Adds validation in _serialize_form_values to reject values containing
\n, \r, or \0. Prevents .env injection where a value like
"3010\nINJECTED_KEY=malicious" could write an extra line to .env.

Not exploitable in the current architecture (Docker Compose and Python
dotenv treat values as literal strings), but closes a defense-in-depth
gap identified during the #854 security audit.

Adds 2 tests: newline injection rejected (400), null byte rejected (400).

Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants